package com.bds.btcdc.model;

import org.nutz.dao.entity.annotation.Column;
import org.nutz.dao.entity.annotation.Id;
import org.nutz.dao.entity.annotation.Table;

import java.math.BigDecimal;
import java.util.Date;

/**
 * Created by DongChenchen on 2018/5/17
 * 各交易所交易记录
 * alter table t_transaction_record add INDEX transaction_indexs(exchange,tid,pair,date)
 */
@Table("t_transaction_record")
public class TransactionRecord {
    @Id
    private Long id;
    @Column
    private String exchange; //交易所
    @Column
    private String pair;//货币对
    @Column
    private String date;// 交易时间
    @Column
    private BigDecimal price;// 交易价格
    @Column
    private BigDecimal amount;// 交易数量
    @Column
    private Long tid;// 交易生成ID
    @Column
    private String type;// buy/sell
    @Column
    private String trade_type;// 委托类型，ask(卖)/bid(买)

    public String getExchange() {
        return exchange;
    }

    public void setExchange(String exchange) {
        this.exchange = exchange;
    }

    public String getPair() {
        return pair;
    }

    public void setPair(String pair) {
        this.pair = pair;
    }

    public String getDate() {
        return date;
    }

    public void setDate(String date) {
        this.date = date;
    }

    public BigDecimal getPrice() {
        return price;
    }

    public void setPrice(BigDecimal price) {
        this.price = price;
    }

    public BigDecimal getAmount() {
        return amount;
    }

    public void setAmount(BigDecimal amount) {
        this.amount = amount;
    }

    public Long getTid() {
        return tid;
    }

    public void setTid(Long tid) {
        this.tid = tid;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getTrade_type() {
        return trade_type;
    }

    public void setTrade_type(String trade_type) {
        this.trade_type = trade_type;
    }
}
